import request from "@/utils/request";
// 获取收货地址数据
export function getAddress() {
  return request({
    url: "member/address",
    method: "get",
  });
}
// 修改收货地址
export function reviseAddress(id, obj) {
  return request({
    url: `member/address/${id}`,
    method: "put",
    data: obj,
  });
}
// 添加收货地址
export function addAddress(data) {
  return request({
    url: "member/address",
    method: "post",
    data: data,
  });
}
// 提交订单
export function submitOrder(data) {
  return request({
    url: "member/order",
    method: "post",
    data: data,
  });
}
// 获取我的订单详情
export function getOrderDetail(id) {
  return request({
    url: `member/order/${id}`,
    method: "get",
  });
}
